<%--
  支付指令核对日报表
  User: zhangxinhai
  Date: 2017/4/18
  Time: 15:03
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ include file="../common/taglibs.jsp" %>
<html>
<head>
    <title>支付指令核对日报表</title>
    <script src="${ctx}/js/views/report/bankTransDetailReport.js"></script>
    <link rel="stylesheet" href="${ctx}/css/common.css">
</head>
<body ng-app="myApp" style="overflow:scroll;overflow-x:hidden">
<core:import url="../common/pageHead.jsp">
    <core:param name="title" value="支付指令核对日报表"/>
</core:import>
<div ng-controller="queryCtrl" class="container-fluid">
    <form id="queryForm" name="queryForm" action="${ctx}/report/bankTransDetailReport/search"
          novalidate w5c-form-validate="vm.validateOptions">
        <table class="table table-bordered table-condensed">
            <tr>
                <td class="text-right">
                    <span class="glyphicon glyphicon-calendar">清算日期</span>
                </td>
                <td>
                    <input type="text" class="{{vm.constant.inputClass}}" uib-datepicker-popup
                           ng-model="vm.queryBean.transConfirmDate" required/>
                </td>
            </tr>
            <tr align="center">
                <td colspan="6">
                    <button type="button" ng-click="vm.queryDetail()" class="btn btn-default"
                            ng-disabled="queryForm.$invalid">
                        查询
                    </button>
                    <button type="button" ng-click="vm.resetForm()" class="btn btn-default">重置</button>
                    <button type="button" down-file="${ctx}/report/bankTransDetailReport/download" params="vm.queryBean"
                            down-file-type="xls" class="btn btn-default">
                        下载
                    </button>
                </td>
            </tr>
        </table>
    </form>
    <div>
        <table table-detail>
            <thead>
            <tr>
                <th rowspan="2">渠道名称</th>
                <th colspan="2">发出支付指令</th>
                <th colspan="2">支付指令回执</th>
                <th colspan="2">成功支付指令</th>
                <th colspan="2">失败支付指令</th>
                <th>失败明细</th>
            </tr>
            <tr>
                <th>笔数</th>
                <th>金额</th>
                <th>笔数</th>
                <th>金额</th>
                <th>笔数</th>
                <th>金额</th>
                <th>笔数</th>
                <th>金额</th>
                <th></th>
            </tr>
            </thead>
            <tbody ng-repeat="bean in vm.pagination.list">
                <tr>
                    <td>{{vm.cached.COMANY_CODE[bean.payOrgCode]}}</td>
                    <td>{{bean.transCountSum}}</td>
                    <td>{{bean.transAmtSum / 100 | currency:""}}</td>
                    <td>{{bean.transCountVerify}}</td>
                    <td>{{bean.transAmtVerify / 100 | currency:""}}</td>
                    <td>{{bean.transCountB}}</td>
                    <td>{{bean.transAmtB / 100 | currency:""}}</td>
                    <td>{{bean.transCountC}}</td>
                    <td>{{bean.transAmtC / 100 | currency:""}}</td>
                    <td>
                        <shiro:hasPermission name="bankTransDetailReport_searchFailure">
                            <button ng-if="bean.transCountC > 0" ng-click="vm.searchFailure(bean)" class="btn btn-default">查看失败明细</button>
                        </shiro:hasPermission>
                    </td>
                </tr>
            </tbody>
            <tfoot>
            <tr style="text-align: center">
                <td>合计</td>
                <td>{{vm.sumObject.transCountSum}}</td>
                <td>{{vm.sumObject.transAmtSum / 100 | currency:""}}</td>
                <td>{{vm.sumObject.transCountVerify}}</td>
                <td>{{vm.sumObject.transAmtVerify / 100 | currency:""}}</td>
                <td>{{vm.sumObject.transCountB}}</td>
                <td>{{vm.sumObject.transAmtB / 100 | currency:""}}</td>
                <td>{{vm.sumObject.transCountC}}</td>
                <td>{{vm.sumObject.transAmtC / 100 | currency:""}}</td>
            </tr>
            </tfoot>
        </table>
    </div>
</div>
<core:import url="../common/nav.jsp"/>
</body>
</html>
